package net.onecloud.onecloud.adapter;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;

import net.onecloud.onecloud.R;
import net.onecloud.onecloud.model.ResultEnterprise;

import java.util.List;

/**
 * Created by zaizai on 16/7/31.
 */
public class EnterpriseAdapter extends BaseQuickAdapter<ResultEnterprise.DataEntity> {
    public EnterpriseAdapter() {
        super(R.layout.rv_items_enterprise, null);
    }

    @Override
    protected void convert(BaseViewHolder baseViewHolder, ResultEnterprise.DataEntity dataEntity) {
        baseViewHolder.setText(R.id.m_ename, dataEntity.getEname())
                .setText(R.id.m_elicense, "工商执照:  " + dataEntity.getLicense())
                .setText(R.id.m_etype, "公司类型:  " + dataEntity.getEtype())
                .setText(R.id.m_escale, "规模:  " + dataEntity.getEscale())
                .setText(R.id.m_ephone, "联系电话:  " + dataEntity.getPhone())
                .setText(R.id.m_eemail, "公司邮箱:  " + dataEntity.getEmail())
                .setText(R.id.m_eaddress, "联系地址:  " + dataEntity.getAddress())
                .itemView.setTag(dataEntity);
    }
}
